#include<bits/stdc++.h>
using namespace std;
#define int long long
signed main() {
	int n;
	cin >> n;
	for (int i = 1; i <= n; i++) {
		string name;
		int age, scores;
		cin >> name >> age >> scores;
		cout << name << " " << age + 1 << " " << (scores * 1.2 > 600 ? 600 : scores * 1.2) << endl;
	}
	return 0;
}
